<template>
    <van-swipe class="my-swipe" :autoplay="3000" indicator-color="white">
        <van-swipe-item v-for="li,index in swiper" :key="index"><img :src="'https:images.weserv.nl/?url='+li.imgSrc"></van-swipe-item>
    </van-swipe>
</template>

<script lang="ts" setup>
import { ref } from "vue"
import { getSwiper } from "@/api/request"


interface swiperFormat {
    link: string
    imgSrc: string
}
let swiper = ref<swiperFormat[]>([]);
getSwiper().then(res => {
    // console.log(res);
    swiper.value = res.data.result;

})
</script>

<style>
.my-swipe img{
    width: 100%;
}
</style>